<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" pageEncoding="UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt_rt" %>

<html>
<head>
    <title>登录页</title>
    <%--echart线图、柱状图、饼图等各种图型库 cdn--%>
    <script type="text/javascript" src="https://cdn.jsdelivr.net/npm/echarts/dist/echarts.min.js"></script>
    <%--jquery cdn--%>
    <script type="text/javascript" src="https://cdn.bootcdn.net/ajax/libs/jquery/3.6.1/jquery.js"></script>
</head>
<body>
<center>
    ${error}
<form action="/add.do" method="post" enctype="multipart/form-data">

    楼号<select name="apartmentId">
        <option value="">请选择</option>
    <c:forEach items="${apartmentList}" var="a">
        <option value="${a.id}">${a.name}</option>
    </c:forEach>
</select><br>
    宿舍<select name="roomId">
    <option value="">请选择</option>
    <c:forEach items="${roomList}" var="r">
        <option value="${r.id}">${r.name}</option>
    </c:forEach>
</select><br>
    学生<select name="studentId">
    <option value="">请选择</option>
    <c:forEach items="${studentList}" var="s">
        <option value="${s.id}">${s.name}</option>
    </c:forEach>
</select><br>
    上传图片：<input type="file" name="picFile"><br>

    <input type="submit" value="入住">
</form>
</center>

</body>
</html>